package com.unitedvision.service;

import java.util.List;

import javax.persistence.EntityNotFoundException;

import com.unitedvision.persistence.domain.CustomerEntity;
import com.unitedvision.persistence.domain.CustomerTypeEntity;

public interface CustomerService {
	void save(CustomerEntity customerEntity);
	void delete(CustomerEntity customerEntity);
	CustomerEntity get(int id) throws EntityNotFoundException;
	CustomerEntity getByName(String name) throws EntityNotFoundException;
	List<CustomerEntity> getAll() throws EntityNotFoundException;
	List<CustomerEntity> getByNameLike(String name) throws EntityNotFoundException;
	List<CustomerEntity> getByType(CustomerTypeEntity type) throws EntityNotFoundException;
	long count();
	
	void save(CustomerTypeEntity customerType);
	void delete(CustomerTypeEntity customerType);
	CustomerTypeEntity getType(int id) throws EntityNotFoundException;
	CustomerTypeEntity getTypeByName(String name) throws EntityNotFoundException;
	List<CustomerTypeEntity> getAllType() throws EntityNotFoundException;
	long countType();
}
